import pandas as pd
import numpy as np

df=pd.read_excel('result2_1.xlsx')
df['年份']=[x.year for x in pd.to_datetime(df['发证日期'])]
df=df.groupby(['标签','年份'])['正式登记证号'].count()
df=df_new.reset_index()




